package com.japp.manager.service;

import java.io.Serializable;
import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import com.japp.base.BaseService;
import com.japp.manager.bean.QtargetBean;
import com.japp.manager.mapper.QtargetMapper;
import com.japp.tools.common.JappLog;
import com.japp.tools.page.Page;

/**
 * 研究报告
 * @author Administrator
 *
 */
@Service
@Transactional(rollbackFor = Exception.class)
public class QtargetService implements BaseService{
	@Autowired
	private QtargetMapper qtargetMapper;
	
	public QtargetBean get(Serializable pk) {
		return null;
	}

	
	public Page<QtargetBean> getPage(Page<QtargetBean> po, QtargetBean obj) {
		try {
			Page<QtargetBean> page = qtargetMapper.getPage(po, obj);
			return page;
		} catch (Exception e) {
			JappLog.log.error("",e);
		}
		return null;
	}

	
	public List<QtargetBean> queryQtargetAll() {
		try {
			return qtargetMapper.queryQtargetAll();
		} catch (Exception e) {
			JappLog.log.error("",e);
		}
		return null;
	}
	
	public QtargetBean findQtargetById(int qtargetBeanId) {
		try {
			return qtargetMapper.findQtargetById(qtargetBeanId);
		} catch (Exception e) {
			JappLog.log.error("",e);
		}
		return null;
	}

	
	public int insertQtarget(QtargetBean qtarget) {
		try {
			return qtargetMapper.insertQtarget(qtarget);
		} catch (Exception e) {
			JappLog.log.error("",e);
		}
		return 0;
	}
	public int deleteQtarget(String[] keys) {
		try {
			int rel = qtargetMapper.deleteQtarget(keys);
			return rel;
		} catch (Exception e) {
			JappLog.log.error("",e);
		}
		return 0;
	}

	
	public int updateQtarget(QtargetBean qtarget) {
		try {
			return qtargetMapper.updateQtarget(qtarget);
		} catch (Exception e) {
			JappLog.log.error("",e);
		}
		return 0;
	}

}
